home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
batchut
/
getday10.zip
/
GETDAY.DOC
< prev
next >
Wrap
Text File
|
1993-12-04
|
2KB
|
70 lines
CKWare's GetDay
Version 1.00
A Batch File enhancing command
to allow testing for the day of the week.
Copyright (c) 1993 Chad Knudson, All Rights Reserved
By Chad Knudson
December 4, 1993
CKWare's GetDay is a batch file utility that places the day of the
week in an environment variable. The reason to have this utility is
to control different events based on the day of the week. For
example, if you want to do a full virus scan on Thursdays, you can
add a few lines in your AUTOEXEC.BAT file and GetDay can trigger the
activity only on Thursdays.
------------
@Echo off
Cls
GETDAY
if not %TODAY%==THURSDAY goto skipscan
cd \scan
scan C:
:skipscan
echo This is our normal everyday portion...
GetDay will fill in a variable TODAY with the day of the week. You
can simply use the DOS if command in your batch file to test the
string for a particular day.
About GetDay and CKWare
-----------------------
GetDay was written by Chad Knudson while attending the University of
North Dakota majoring in Computer Science and Mathematics. It was
written in 'C' and compiled with Microsoft C 7.0.
Chad has developed a number of utilities for Bulletin Board Systems
as well as DOS utilities. To see the latest collection of CKWare
products, call City Lites BBS (701) 772-5399.
Questions, comments, and bug reports can be e-mailed to:
Internet
──────────
knudson@cs.und.nodak.edu
RIME
──────────
->CITYLITE
FIDO
──────────
1:14/644
A special thanks goes out to H. D. Todd, Wesleyan University, for
steering me in the right direction as to how one could manipulate
variables in the parent process' environment (the documentation in
the C Compilers said that this could not be done, at least not using
the putenv() function that the compiler provides.) Without his help
this program wouldn't have been possible.